import time
from selenium import webdriver
from selenium.webdriver.common.by import By
from selenium.webdriver.support.ui import Select


driver = webdriver.Chrome(r'D:\bianchengerbianchenger\driver\chromedriver.exe')
driver.get('https://www.booking.cn/index.zh-cn.html')
driver.maximize_window()
time.sleep(1)


driver.find_element(By.CLASS_NAME,"bui-button__text.js-accept-continue").click()
time.sleep(2)

#下拉滚动条   js
js='var q=document.documentElement.scrollTop=150'
driver.execute_script(js)

driver.find_element(By.CSS_SELECTOR,'[id="ss"]').send_keys('长沙')   #输入长沙

driver.find_element(By.CSS_SELECTOR,'[class="bk-icon -experiments-calendar sb-date-picker_icon-svg"]').click()
driver.find_element(By.CSS_SELECTOR,'[data-date="2022-09-21"]').click()
driver.find_element(By.CSS_SELECTOR,'[data-date="2022-09-23"]').click()

driver.find_element(By.CSS_SELECTOR,'[class="js-sb-submit-text "]').click()


#时间
driver.find_element()
